package hcn.response.bean;

import lombok.ToString;

import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper;
import javax.xml.bind.annotation.XmlRootElement;
import java.io.Serializable;
import java.util.List;

/**
 * @program: 3.4.02
 * @description: 病历质控提醒信息相应体
 * @author: zangsf
 * @create: 2021-08-29 21:54
 **/
@ToString
@XmlRootElement(name = "BSXml")
public class CaseInfoRemindRepHisBean implements Serializable {
    private MsgHeader msgHeader;
    private MsgBody msgBody;

    @XmlElement(name = "MsgHeader")
    public MsgHeader getMsgHeader() {
        return msgHeader;
    }

    public void setMsgHeader(MsgHeader msgHeader) {
        this.msgHeader = msgHeader;
    }

    @XmlElement(name = "MsgBody")
    public MsgBody getMsgBody() {
        return msgBody;
    }

    public void setMsgBody(MsgBody msgBody) {
        this.msgBody = msgBody;
    }

    @ToString
    @XmlRootElement(name = "MsgHeader")
    public static class MsgHeader {
        private String organization;
        private String sender;
        private String serviceType;
        private String msgType;
        private String msgVersion = "2.0";

        @XmlElement(name = "Organization")
        public String getOrganization() {
            return organization;
        }

        public void setOrganization(String organization) {
            this.organization = organization;
        }

        @XmlElement(name = "Sender")
        public String getSender() {
            return sender;
        }

        public void setSender(String sender) {
            this.sender = sender;
        }

        @XmlElement(name = "ServiceType")
        public String getServiceType() {
            return serviceType;
        }

        public void setServiceType(String serviceType) {
            this.serviceType = serviceType;
        }

        @XmlElement(name = "MsgType")
        public String getMsgType() {
            return msgType;
        }

        public void setMsgType(String msgType) {
            this.msgType = msgType;
        }

        @XmlElement(name = "MsgVersion")
        public String getMsgVersion() {
            return msgVersion;
        }

        public void setMsgVersion(String msgVersion) {
            this.msgVersion = msgVersion;
        }
    }

    @ToString
    @XmlRootElement(name = "MsgBody")
    public static class MsgBody {
        private String status;
        private String code;
        private String detail;
        private CaseInfoRemind data;

        @XmlElement(name = "Status")
        public String getStatus() {
            return status;
        }

        public void setStatus(String status) {
            this.status = status;
        }

        @XmlElement(name = "Code")
        public String getCode() {
            return code;
        }

        public void setCode(String code) {
            this.code = code;
        }

        @XmlElement(name = "Detail")
        public String getDetail() {
            return detail;
        }

        public void setDetail(String detail) {
            this.detail = detail;
        }

        @XmlElement(name = "Data")
        public CaseInfoRemind getData() {
            return data;
        }

        public void setData(CaseInfoRemind data) {
            this.data = data;
        }
    }

    @ToString
    @XmlRootElement(name = "Data")
    public static class CaseInfoRemind {
        private CaseInfoRemindData request;

        @XmlElement(name = "RequestList")
        public CaseInfoRemindData getRequest() {
            return request;
        }

        public void setRequest(CaseInfoRemindData request) {
            this.request = request;
        }
    }

    @ToString
    @XmlRootElement(name = "RequestList")
    public static class CaseInfoRemindData {
        private String visitId;                                          //住院号
        private String hospizationId;                                    //住院号码
        private String sourcePatientId;                                  //业务系统患者档案ID
        private List<QualityRemindlist> qualityRemindlists;              //质控提醒列表

        @XmlElement(name = "VisitId")
        public String getVisitId() {
            return visitId;
        }

        public void setVisitId(String visitId) {
            this.visitId = visitId;
        }

        @XmlElement(name = "HospizationId")
        public String getHospizationId() {
            return hospizationId;
        }

        public void setHospizationId(String hospizationId) {
            this.hospizationId = hospizationId;
        }

        @XmlElement(name = "SourcePatientId")
        public String getSourcePatientId() {
            return sourcePatientId;
        }

        public void setSourcePatientId(String sourcePatientId) {
            this.sourcePatientId = sourcePatientId;
        }

        @XmlElementWrapper(name = "QualityRemindlists")
        @XmlElement(name = "QualityRemindlist")
        public List<QualityRemindlist> getQualityRemindlists() {
            return qualityRemindlists;
        }

        public void setQualityRemindlists(List<QualityRemindlist> qualityRemindlists) {
            this.qualityRemindlists = qualityRemindlists;
        }

        @ToString
        @XmlRootElement(name = "QualityRemindlist")
        public static class QualityRemindlist {
            private String remindType;                                       //提醒类型 1、时限提醒2、次数提醒
            private List<QualityRemindDetaillist> qualityRemindDetaillists;  //质控提醒明细

            @XmlElement(name = "RemindType")
            public String getRemindType() {
                return remindType;
            }

            public void setRemindType(String remindType) {
                this.remindType = remindType;
            }

            @XmlElementWrapper(name = "QualityRemindDetaillists")
            @XmlElement(name = "QualityRemindDetaillist")
            public List<QualityRemindDetaillist> getQualityRemindDetaillists() {
                return qualityRemindDetaillists;
            }

            public void setQualityRemindDetaillists(List<QualityRemindDetaillist> qualityRemindDetaillists) {
                this.qualityRemindDetaillists = qualityRemindDetaillists;
            }

            @ToString
            @XmlRootElement(name = "QualityRemindDetaillist")
            public static class QualityRemindDetaillist {
                private String medicalRecordId;                              //病历编号
                private String medicalRecordName;                            //病历名称
                private String startTime;                                    //开始时间
                private String endTime;                                      //截止时间
                private String timeLimit;                                    //超过时限（小时）
                private String isSetup;                                      //是否创建
                private String shouldQuantity;                               //是否创建
                private String replenishedQuantity;                          //是否创建
                private String supplementedQuantity;                         //是否创建

                @XmlElement(name = "MedicalRecordId")
                public String getMedicalRecordId() {
                    return medicalRecordId;
                }

                public void setMedicalRecordId(String medicalRecordId) {
                    this.medicalRecordId = medicalRecordId;
                }

                @XmlElement(name = "MedicalRecordName")
                public String getMedicalRecordName() {
                    return medicalRecordName;
                }

                public void setMedicalRecordName(String medicalRecordName) {
                    this.medicalRecordName = medicalRecordName;
                }

                @XmlElement(name = "StartTime")
                public String getStartTime() {
                    return startTime;
                }

                public void setStartTime(String startTime) {
                    this.startTime = startTime;
                }

                @XmlElement(name = "EndTime")
                public String getEndTime() {
                    return endTime;
                }

                public void setEndTime(String endTime) {
                    this.endTime = endTime;
                }

                @XmlElement(name = "TimeLimit")
                public String getTimeLimit() {
                    return timeLimit;
                }

                public void setTimeLimit(String timeLimit) {
                    this.timeLimit = timeLimit;
                }

                @XmlElement(name = "IsSetup")
                public String getIsSetup() {
                    return isSetup;
                }

                public void setIsSetup(String isSetup) {
                    this.isSetup = isSetup;
                }

                @XmlElement(name = "ShouldQuantity")
                public String getShouldQuantity() {
                    return shouldQuantity;
                }

                public void setShouldQuantity(String shouldQuantity) {
                    this.shouldQuantity = shouldQuantity;
                }

                @XmlElement(name = "ReplenishedQuantity")
                public String getReplenishedQuantity() {
                    return replenishedQuantity;
                }

                public void setReplenishedQuantity(String replenishedQuantity) {
                    this.replenishedQuantity = replenishedQuantity;
                }

                @XmlElement(name = "SupplementedQuantity")
                public String getSupplementedQuantity() {
                    return supplementedQuantity;
                }

                public void setSupplementedQuantity(String supplementedQuantity) {
                    this.supplementedQuantity = supplementedQuantity;
                }
            }
        }
    }
}
